﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace XsqTech.SmartOA.Domain.Table
{
    /// <summary>
    /// 部门实体类
    /// </summary>
    public class Department:Audit
    {
        [Key]
        public Guid DepId { get; set; }

        /// <summary>
        /// 部门名称
        /// </summary>
        [StringLength(20)]
        [Required]
        public string Name { get; set; }

        /// <summary>
        /// 层级Id
        /// </summary>
        [Required]
        [StringLength(20)]
        public string CascadeId { get; set; } = "0";

        /// <summary>
        /// 上级部门Id
        /// </summary>
        public Guid ParentId { get; set; }

        /// <summary>
        /// 状态 0：禁用、 1： 启用
        /// </summary>
        public int Status { get; set; } = 1;
        public List<Department> Dlist { get; set; }
        /// <summary>
        /// 逻辑删除
        /// </summary>

        public int IsChecks { get; set; } = 0;
    }
}
